AddCSLuaFile("cl_init.lua")
AddCSLuaFile("shared.lua")

include('shared.lua')

function ENT:OnRemove()
end

function ENT:KeyValue(key,value)
end

function ENT:Initialize()
	self.Entity:PhysicsInit(SOLID_VPHYSICS)
	self.Entity:SetMoveType(MOVETYPE_VPHYSICS)
	self.Entity:SetSolid(SOLID_VPHYSICS)
	self.Entity:SetCollisionGroup(COLLISION_GROUP_INTERACTIVE)
	
	local phys = self.Entity:GetPhysicsObject()
	if phys:IsValid() then
		phys:EnableMotion(true)
		phys:Wake()
	end
end

function ENT:Use(activator,caller)
	if (not IsValid(activator)) or (not activator:IsPlayer()) or (activator:WSIsPigeon()) then
		return
	end
	
	activator:WSGive(self.class,1)
	self:Remove()
end

function ENT:Think()
end

function ENT:UpdateTransmitState()
	return TRANSMIT_PVS
end
